package com.wd.elec.mapper;

import java.util.Date;
import java.util.List;

import com.wd.elec.domain.AttendReport;
import com.wd.elec.domain.DeptAttendReport;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;
import org.springframework.stereotype.Repository;

/**
 * 考勤统计Mapper接口
 *
 * @author liumingkun
 * @date 2023-11-21
 */
@Mapper
@Repository
public interface AttendReportMapper {
    /**
     * 查询考勤统计
     *
     * @param reportId 考勤统计主键
     * @return 考勤统计
     */
    AttendReport selectAttendReportByReportId(Long reportId);

    /**
     * 查询考勤统计列表
     *
     * @param attendReport 考勤统计
     * @return 考勤统计集合
     */
    List<AttendReport> selectAttendReportList(AttendReport attendReport);

    /**
     * 新增考勤统计
     *
     * @param attendReport 考勤统计
     * @return 结果
     */
    int insertAttendReport(AttendReport attendReport);

    /**
     * 修改考勤统计
     *
     * @param attendReport 考勤统计
     * @return 结果
     */
    int updateAttendReport(AttendReport attendReport);

    /**
     * 删除考勤统计
     *
     * @param reportId 考勤统计主键
     * @return 结果
     */
    int deleteAttendReportByReportId(Long reportId);

    /**
     * 批量删除考勤统计
     *
     * @param reportIds 需要删除的数据主键集合
     * @return 结果
     */
    int deleteAttendReportByReportIds(Long[] reportIds);

    int deleteAttendReport(@Param("attendYear") Integer attendYear, @Param("attendMonth") Integer attendMonth);

    int attendReportJob(@Param("attendYear") Integer attendYear, @Param("attendMonth") Integer attendMonth, @Param("startTime") Date startTime, @Param("endTime") Date endTime);

    List<DeptAttendReport> selectDeptAttendReport(DeptAttendReport deptAttendReport);
}
